<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<script>
			function printName(){
				var name = "张三";
				alert(name);
			}
		</script>
	</head>
	<body>
		<form action="#">
			<input type="button" onclick="printName()" value="测试"/>
		</form>
	</body>
</html>
